/*
 * Copyright (c) Huawei Technologies Co., Ltd. 2022-2022. All rights reserved.
 * Description: 性能评估器相关头文件
 * Author: qingjicheng
 * Create: 2022-8-1
 */

#ifndef TOPO_SPLIT_H
#define TOPO_SPLIT_H
#include "graph_common_def.h"

namespace HcclEvaluator {
class TopoSplit {
public:
    explicit TopoSplit();
    virtual ~TopoSplit();
    HcclResult Split(HcclTopology* topo, std::vector<AdjacencyMatrix<>> &matrixes);
private:
    void GetNodeList(HcclTopology* topo, std::vector<u32> &nodeList);
    void GetNodeIdIndexMap(std::vector<u32> &nodeList, std::unordered_map<u32, u32> &outMap);
    HcclResult CheckNodeList(std::vector<u32> &nodeList);
    HcclResult SetAllEdges(HcclTopology* topo, AdjacencyMatrix<> &matrix);
};
}
#endif